const mongoose = require('mongoose');

mongoose.connect('mongodb://localhost/h5');

const UserSchema = new mongoose.Schema({
    userID: Number,
    username:String,
    password:String,
    sex: String,
    age: Number,
    phone: Number,
    address: String
})

const BillSchema = new mongoose.Schema({
    proname:String,
    prounit: String,
    supplier: String,
    number: Number,
    money:Number,
    flag:String,
    datatime:String
})

const User = mongoose.model('users',UserSchema);
const Bill = mongoose.model('bill',BillSchema);
// console.log(1);
module.exports = {User,Bill};